package com.yztc.orangeentertainment.ui.main.channalfragment;

import com.yztc.orangeentertainment.bean.channalbean.ChannalTitleDataBean;

import java.util.List;

/**
 * Created by My on 2016/10/5.
 */
public class ChannalPresenter implements ChannalContract.Presenter{
    private ChannalContract.Modle modle;
    private ChannalContract.View view;

    public ChannalPresenter( ChannalContract.View view) {
        this.modle = new ChannalModle();
        this.view = view;
    }

    @Override
    public void getChannalTitleFromNet() {
        modle.getChannalTitle(new OnLoadChannalListener() {
            @Override
            public void onSuccess(List<ChannalTitleDataBean> list) {
                view.onChannalTitleSucess(list);
            }

            @Override
            public void onFailure(String e) {
                view.onChannalTitleFail(e);
            }
        });
    }

    @Override
    public void getChannalTitleFromDb() {

    }
}
